home *** CD-ROM | disk | FTP | other *** search
/ Info-Mac 3 / Info_Mac_1994-01.iso / Development / Source / Menu Fixer 1.0 Source / Menu fixer ƒ / Fix code ƒ / fix help.c < prev    next >
Encoding:
C/C++ Source or Header  |  1993-11-15  |  5.3 KB  |  150 lines  |  [TEXT/KAHL]

  1. /**********************************************************************\
  2.  
  3. File:        fix help.c
  4.  
  5. Purpose:    This module handles the help windows.
  6.  
  7.  
  8. Menu Fixer -=- synchronize menu IDs and menu resource IDs
  9. Copyright (C) 1993 Mark Pilgrim
  10.  
  11. This program is free software; you can redistribute it and/or modify
  12. it under the terms of the GNU General Public License as published by
  13. the Free Software Foundation; either version 2 of the License, or
  14. (at your option) any later version.
  15.  
  16. This program is distributed in the hope that it will be useful,
  17. but WITHOUT ANY WARRANTY; without even the implied warranty of
  18. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  19. GNU General Public License for more details.
  20.  
  21. You should have received a copy of the GNU General Public License
  22. along with this program in a file named "GNU General Public License".
  23. If not, write to the Free Software Foundation, 675 Mass Ave,
  24. Cambridge, MA 02139, USA.
  25.  
  26. \**********************************************************************/
  27.  
  28. #include "fix help.h"
  29.  
  30. void DrawHelp(int whichHelp)
  31. {
  32.     GrafPtr        curPort;
  33.     
  34.     GetPort(&curPort);
  35.     EraseRect(&(curPort->portRect));
  36.  
  37.     MoveTo(10,15);
  38.     TextFont(3);
  39.     TextSize(9);
  40.     switch (whichHelp)
  41.     {
  42.         case 0:
  43.             DrawHelpUse();
  44.             break;
  45.         case 1:
  46.             DrawHelpCopyright();
  47.             break;
  48.         case 2:
  49.             DrawHelpContact();
  50.             break;
  51.     }
  52. }
  53.  
  54. void DrawHelpUse(void)
  55. {
  56.     DrawString("\pApple Computer, Inc., in their infinite wisdom, has set up the");
  57.     MoveTo(10,27);
  58.     DrawString("\pMENU resource to be as flexible as possible.  Each MENU");
  59.     MoveTo(10,39);
  60.     DrawString("\presource has a unique resource ID, like any resource, but");
  61.     MoveTo(10,51);
  62.     DrawString("\pthis resource ID actually has nothing to do with the menu ID");
  63.     MoveTo(10,63);
  64.     DrawString("\pby which you reference the menu.  The internal menu ID, within");
  65.     MoveTo(10,75);
  66.     DrawString("\pthe resource, is the ID the toolbox uses.  The problem is that");
  67.     MoveTo(10,87);
  68.     DrawString("\pthis is not automatically set to the resource ID!  If you are");
  69.     MoveTo(10,99);
  70.     DrawString("\pexpecting to reference your menus by the MENU resource IDs,");
  71.     MoveTo(10,111);
  72.     DrawString("\pyour menus may be scrambled, or they may not show up at all.");
  73.     MoveTo(10,135);
  74.     DrawString("\pMenu Fixer looks at each MENU resource in a file and checks");
  75.     MoveTo(10,147);
  76.     DrawString("\pthe resource ID against the internal menu ID for that MENU");
  77.     MoveTo(10,159);
  78.     DrawString("\presource.  If they don’t match, Menu Fixer will tell you this");
  79.     MoveTo(10,171);
  80.     DrawString("\pand offer to fix the problem.  NOTE: if you are not having a");
  81.     MoveTo(10,183);
  82.     DrawString("\pproblem with your menus, do not try Menu Fixer.  There is no");
  83.     MoveTo(10,195);
  84.     DrawString("\psense creating problems where there are none to begin with!");
  85. }
  86.  
  87. void DrawHelpCopyright(void)
  88. {
  89.     DrawString("\pMenu Fixer is copyright ©1993 Mark Pilgrim.  This");
  90.     MoveTo(10,27);
  91.     DrawString("\pprogram is free; you can redistribute it and/or modify it");
  92.     MoveTo(10,39);
  93.     DrawString("\punder the terms of the GNU General Public License as published");
  94.     MoveTo(10,51);
  95.     DrawString("\pby the Free Software Foundation; either version 2 of the");
  96.     MoveTo(10,63);
  97.     DrawString("\pLicense, or (at your option) any later version.");
  98.     MoveTo(10,87);
  99.     DrawString("\pMenu Fixer is distributed in the hope that it will be useful,");
  100.     MoveTo(10,99);
  101.     DrawString("\pbut WITHOUT ANY WARRANTY; without even the implied");
  102.     MoveTo(10,111);
  103.     DrawString("\pwarranty of MERCHANTABILITY or FITNESS FOR A");
  104.     MoveTo(10,123);
  105.     DrawString("\pPARTICULAR PURPOSE.  See the GNU General Public License");
  106.     MoveTo(10,135);
  107.     DrawString("\pfor more details.");
  108.     MoveTo(10,159);
  109.     DrawString("\pYou should have received a copy of the GNU General Public");
  110.     MoveTo(10,171);
  111.     DrawString("\pLicense along with this program; if not, write to the Free");
  112.     MoveTo(10,183);
  113.     DrawString("\pSoftware Foundation, Inc., 675 Mass Ave, Cambridge, MA,");
  114.     MoveTo(10,195);
  115.     DrawString("\p02139, USA.");
  116. }
  117.  
  118. void DrawHelpContact(void)
  119. {
  120.     DrawString("\pAll Macintosh users should feel free to contact me for any of");
  121.     MoveTo(10,27);
  122.     DrawString("\pthe following reasons: reporting bugs or suggestions about");
  123.     MoveTo(10,39);
  124.     DrawString("\pMenu Fixer or any other program I’ve written; discussing the");
  125.     MoveTo(10,51);
  126.     DrawString("\ppossibility of collaborating on future programming projects;");
  127.     MoveTo(10,63);
  128.     DrawString("\pdiscussing the virus I wrote and released (MBDF-A); discussing");
  129.     MoveTo(10,75);
  130.     DrawString("\pways to keep potential virus-writers from becoming actual");
  131.     MoveTo(10,87);
  132.     DrawString("\pvirus-writers; discussing techniques for really good backrubs.");
  133.     MoveTo(10,111);
  134.     DrawString("\pMy e-mail address is f8dy@netaxs.com.  To send me e-mail");
  135.     MoveTo(10,123);
  136.     DrawString("\panonymously, mail to an48382@anon.penet.fi.  (Due to the");
  137.     MoveTo(10,135);
  138.     DrawString("\pdouble-blind system, you will be allocated an anonymous I.D.");
  139.     MoveTo(10,147);
  140.     DrawString("\pwhich will keep your identity hidden.)  To send me encrypted");
  141.     MoveTo(10,159);
  142.     DrawString("\pmail, e-mail me requesting my PGP 2.2 public key.  If you do");
  143.     MoveTo(10,171);
  144.     DrawString("\pnot have e-mail access, my home address is 1130 Radnor Hill");
  145.     MoveTo(10,183);
  146.     DrawString("\pRoad, Wayne PA, 19087-2203, USA.  Obviously, it will take");
  147.     MoveTo(10,195);
  148.     DrawString("\pme much longer to reply to snail-mail; use it as a last resort.");
  149. }
  150.